<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<%@page contentType="text/html; charset=utf-8"%> 
<%@ taglib uri="http://struts-menu.sf.net/tag" prefix="menu" %> 
<%@ taglib uri="http://www.opensymphony.com/sitemesh/decorator" prefix="decorator" %>
<html>
<head>     	
<title><decorator:title default="智能资源管理系统" /></title>
<link rel="stylesheet" type="text/css" media="screen" href="<%=request.getContextPath()%>/styles/menu.css" />    
<script type="text/javascript" src="<%=request.getContextPath()%>/scripts/tabs.js"></script>
<decorator:head />
<% 
String USER_ID = "";
try
{
	USER_ID = request.getSession().getAttribute("stxtUName").toString();  
}catch(Exception e)
{
	response.sendRedirect("/btsm/login.jsp");	
}
%>
<style tpye="text/css">
body {
	background: #e0eef5;
	font-family: Verdana, Helvetica, Arial, sans-serif;
	font-size: 80%;
	margin: 0px;
	padding: 0px;
}

</style>

</head>

<script>
 
function logout()
{
	document.getElementById("logoutForm").submit();	
}
</script>
<!-- SCROLL="YES"-->      
<body oncontextmenu=self.event.returnValue=false onselectstart="return false" SCROLL="YES">
	<form action="<%=request.getContextPath()%>/logout.do" id="logoutForm"></form>

	<table width="100%" height="100%" cellspacing="0" cellpadding="0">
		<tr height=20>
			<td width="100%" valign="top" > 
				<table border="0" cellspacing="0" cellpadding="0" class="headerTableCSS">
				  <tr>
						<td nowrap rowspan=2 valign="top"> 
						   <a href="#" class="headerImageCSS"> 
							<img src="<%=request.getContextPath()%>/styles/images/66.gif" border="0" alt="header" title="header" />
							</a>
						</td>   
						
						<td class="topCSS">
							<%=USER_ID%> 
							&nbsp;&nbsp;|&nbsp;&nbsp;
							<a href="<%=request.getContextPath()%>/logout.do" class="topCSSOther">Logout</a>
							&nbsp;&nbsp;&nbsp;&nbsp;
							&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
							</nobr></nobr>
						</td>
				   </tr>  
				   
				</table>
			</td>
		</tr>
		<tr>
			<td width="100%" valign="top" style="margin-top:10px;">
				<menu:useMenuDisplayer name="TabbedMenu" bundle="org.apache.struts.action.MESSAGE">
					<menu:displayMenu strUserID="<%=USER_ID%>"/>
				</menu:useMenuDisplayer>
			</td>
		</tr>
		
		
		
		<tr> 
			<td height="80%">
				<div ><decorator:body/></div>
			</td>
		</tr>
		
		<tr>
			<!--  <td align="center"><p>智能资源管理系统 1.0 Copyright &copy; 2003-2010</p></td>-->
		</tr>
	</table>
<script>

var menuUls = document.getElementsByTagName("ul");
for (i = 0; i < menuUls.length; i++) {
	if (menuUls[i].className == "menuList") {
		decorateMenu(menuUls[i]);
	}
}

if(!hasMenuSelected)
{
	var menuNode = unescape(getCookie("lastMenuNode"));	
	var uls = document.getElementsByTagName("ul");
	var allMenuNode;
    for (i = 0; i < uls.length; i++) {
        if (uls[i].className == "menuList") {
            allMenuNode = uls[i];
			break;
        }
    }
	
	var items = allMenuNode.getElementsByTagName("li");
	for (var i=0; i < items.length; i++) {
		var url = items[i].firstChild.getAttribute("href"); 
		if (menuNode.indexOf(url) != -1) {   
			if (items[i].parentNode.className == "submenu") {
				items[i].firstChild.className="selected";
				items[i].parentNode.parentNode.className="selected";
			} else {            
				items[i].className+="selected";
			}
		} 
	}
	
}
</script>
  </body>
</html>

